/*
@hehung
email: 1398660197@qq.com
wechat: hehung95
reproduced and please indicate the source @hehung
*/

#include "app_common.h"

#define BEEP_DEBUG
#undef BEEP_DEBUG

#ifdef BEEP_DEBUG
#include <stdio.h>
#define LOG(fmt, ...)        printf(fmt, ##__VA_ARGS__)
#endif


static bool beep_status = false; 


void Beep_Init(void)
{
	// Do not need to be initialization
}

void Beep_On(void)
{
	beep_status = true;
	(void)R_IOPORT_PinWrite(&g_ioport_ctrl, BEEP_CTRL_PIN, BSP_IO_LEVEL_HIGH);
}

void Beep_Off(void)
{
	beep_status = false;
	(void)R_IOPORT_PinWrite(&g_ioport_ctrl, BEEP_CTRL_PIN, BSP_IO_LEVEL_LOW);
}

bool Beep_GetStatus(void)
{
	return beep_status;
}
